timeTable={}
timeIndex=0
function setTimeout(func,time)
    tmr.alarm(timeIndex,time,0,func)
    if timeIndex < 6 then
        timeIndex=timeIndex+1
    else
        timeIndex=0
    end
end

function setInterval(func,time)
    tmr.alarm(timeIndex,time,1,func)
    if timeIndex < 6 then
        timeIndex=timeIndex+1
    else
        timeIndex=0
    end
end
function call(name)
    file.remove("user.lua")
    file.open("user.lua","w+")
    file.writeline(name)
    file.close()
    dofile("user.lua")
end

function debug(d)
    if DEBUG then
        print(tmr.time(),type(d),d)
    end
end
